﻿<Window x:Class="ToDoListReminder.ConfigWindow"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:vm="clr-namespace:ToDoListReminder.ViewModel"
    Title="Configuration" Height="300" Width="404" WindowStartupLocation="CenterOwner" Icon="/ToDoListReminder;component/ToDoListReminder.ico" ShowInTaskbar="False" WindowStyle="ToolWindow">
    
	<Window.Resources>
		<vm:CommandProxy x:Key="CommandAdd" Command="{Binding CommandAdd}"/>
		<vm:CommandProxy x:Key="CommandEdit" Command="{Binding CommandEdit}"/>
		<vm:CommandProxy x:Key="CommandDelete" Command="{Binding CommandDelete}"/>
		<vm:CommandProxy x:Key="CommandOk" Command="{Binding CommandOk}"/>
	</Window.Resources>
	<DockPanel>
		<StackPanel DockPanel.Dock="Bottom" Orientation="Horizontal" HorizontalAlignment="Center">
			<Button Command="{StaticResource CommandAdd}">_Add</Button>
			<Button Command="{StaticResource CommandEdit}">_Edit</Button>
			<Button Command="{StaticResource CommandDelete}">_Delete</Button>
			<Button Command="{StaticResource CommandOk}" IsDefault="True">_OK</Button>
			<Button IsCancel="True">Cancel</Button>
		</StackPanel>
		
		<Label DockPanel.Dock="Top" Target="{Binding ElementName=listBoxProjects}">_Projects:</Label>
		<ListBox DockPanel.Dock="Top" Name="listBoxProjects" ItemsSource="{Binding Path=Config.Projects}" DisplayMemberPath="FileName"/>
	</DockPanel>
</Window>
